<?php use_helper('Number') ?>
<?php /* @var $product Product */ ?>

<div class="category_title">
    <?php 	// product path ?>
    <?php $arBranch = Category::getBranchById($product->getCategoryId()) ?>

    <?php foreach( $arBranch as $key => $val ): ?>
        <?php if($val['id'] == $product->getCategoryId()): ?>
            <?php echo image_tag(
                            'arrow.png'
                            , array(
                                'border' => '0'
                                , 'alt' => ''
                                , 'style' => 'margin-bottom: 2px;'
                            )
                        ) ?>
            <?php echo link_to(
                            $val['name']
                            , 'product/list/?id=' . $val['id']
                        ) ?>
        <?php else: ?>
            <?php echo link_to(
                            $val['name']
                            , 'product/list/?id=' . $val['id']
                        ) ?>&nbsp;
            <?php echo image_tag(
                            'arrow.png'
                            , array(
                                'border' => '0'
                                , 'alt' => ''
                                , 'style' => 'margin-bottom: 2px;'
                            )
                        ) ?>&nbsp;
        <?php endif; ?>
    <?php endforeach; ?>
    <?php echo image_tag(
                    'arrow.png'
                    , array(
                        'border' => '0'
                        , 'alt' => ''
                        , 'style' => 'margin-bottom: 2px;'
                    )
                ) ?>
    <?php echo $product->getName() ?>
</div>

<table class="product_description" cellspacing="0" cellpadding="0">
<tr>
<td width="50%" valign="top">
    <div class="product_image_big">
        <?php if( $product->hasPhoto($product->getId()) ): ?>
            <?php echo image_tag(Files::getDirPath('tiny').$product->getPhotoName($product->getId())
                            , array(
                                'border' => '0'
                            )
                        ) ?> 
            
        <?php //echo $product->getPhotoName() ?>
        <?php else: ?>
            ---
        <?php endif; ?>
    </div>

</td>
<td width="50%" valign="top">
    <div class="product_title_big">
        <?php echo $product->getName() ?>
    </div>
    <div class="product_desc_info">
    <?php if( get_user_id() ): ?>
        <div class="bold">
            <?php echo __('Price') ?>: <?php echo format_currency($product->getPriceByCurrencyCode($sf_user->getAttribute('currency', 'EUR')), $sf_user->getAttribute('currency', 'EUR')) ?>
        </div>
    <?php endif; ?>    
        <div class="">
            <?php echo __('Code') ?>: <?php echo $product->getCode() ?>
        </div>
        <div class="">
            <?php echo __('Quantity') ?>: <?php echo $product->getQuantity() ?>
        </div>
    </div>
    <div class="product_summary">
        <!--    <?php echo __('Summary') ?>:    -->
        <?php echo $product->getSummary() ?>
    </div>
    <div class="product_summary">
        <?php echo __('Code') ?>: <?php echo $product->getCode() ?>
    </div>
    <div class="">
        <!--    <?php echo __('Text') ?>:   -->
        <?php echo $product->getText() ?>
    </div>
</div>

</td>
</tr>
</table>
